package org.hiucung.hlsdownloader.bean

/**
 * @Classname M3U8TaskState
 * @Description M3U8状态
 * @Date 2025/8/21 10:43
 * @Created by Kicc
 */
sealed class M3U8TaskState {
    object WaitingDownload : M3U8TaskState() // 等待下载
    data class Downloading(
        val current: Int,
        val total: Int,
        val currentUrl: String
    ) : M3U8TaskState() // 正在下载
    data class DownloadCompleted(val downloadedFiles: List<String>) : M3U8TaskState() // 下载完成
    object WaitingMerge : M3U8TaskState() // 等待合并
    data class Merging(val current: Int, val total: Int) : M3U8TaskState() // 正在合并
    data class MergeCompleted(val outFilePath: String) : M3U8TaskState() // 合并完成
    data class Error(val message: String) : M3U8TaskState() // 错误
}